package com.dinim.physics2D;

import java.util.Iterator;
import java.util.List;

import com.dinim.object.IObject2D;

public class AabbLineBoundingBox extends Aabb{

    private int splitting;
    
    public AabbLineBoundingBox(double height, double width, int lines, int columns, int splitting) {
        super(height, width, lines, columns);
        this.splitting = splitting;
    }

    public void addObject(IObject2D object) {
        List boundingboxes = object.getLineBoundingBoxes(splitting);
        Iterator it = boundingboxes.iterator();
        while(it.hasNext()){
            addObjectToArray(object, (IBoundingBox2D)it.next());
        }
    }


}
